package com.bawei.home.model

import androidx.lifecycle.MutableLiveData
import com.bw.lib_mvvm.entity.BaseVideoEntity
import com.bw.lib_mvvm.entity.SimpleVideo
import com.bawei.home.repo.SimpleVideoRepo
import com.bw.lib_mvvm.BaseViewModel
import com.bw.lib_mvvm.entity.HomeType

class SimpleVideoModel : BaseViewModel(){

    val success= MutableLiveData<BaseVideoEntity<SimpleVideo>>()
    val failed= MutableLiveData<String>()
    val typesuccess= MutableLiveData<HomeType>()
    val typefailed= MutableLiveData<String>()
    private val repo= SimpleVideoRepo()

    fun getVideoModel(
        page:Int,
        pagesize :Int,
    ){
        repo.getVideo(page,pagesize,success,failed)
    }
    fun getTypeModel(

    ){
        repo.getType(typesuccess,typefailed)
    }

}